
function confirmDelete()
{

var agree = confirm("Are you sure you want to delete this Record ? This action cannot be undone");

if(agree)
        return true;
else
        return false;

}



function confirmUserDelete()
{

var agree = confirm("Are you sure you want to delete this User ? Deleting this user will delete all domains this user owns");

if(agree)
        return true;
else
        return false;

}


function checkAll(FormName, FieldName, CheckValue)
{
  if(!document.forms[FormName])
    return;
  var objCheckBoxes = document.forms[FormName].elements[FieldName];
  if(!objCheckBoxes)
    return;
  var countCheckBoxes = objCheckBoxes.length;
  if(!countCheckBoxes)
    objCheckBoxes.checked = CheckValue;
  else
    // set the check value for all check boxes
    for(var i = 0; i < countCheckBoxes; i++)
      objCheckBoxes[i].checked = CheckValue;
}
